﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="U4008RecordList.aspx.cs" Inherits="IHISCETeim.Web.MachineSys.UserModel.U4008RecordList" %>
<form id="pagerForm" method="post" action="UserModel/U4008RecordList.aspx">
<input type="hidden" name="CustomerName" value="<%=CustomerName %>" />
<input type="hidden" name="SerialNumber" value="<%=SerialNumber %>" />
<input type="hidden" name="RealName" value="<%=RealName %>" />
<input type="hidden" name="AgentName" value="<%=AgentName %>" />
<input  type="hidden" name="IsComplete" value="<%=IsComplete %>" />
<input type="hidden" name="CallDateFrom" value="<%=CallDateFrom %>" />
<input type="hidden" name="CallDateTo" value="<%=CallDateTo %>" />
<input type="hidden" name="ShowTimeInput" value="<%=ShowTimeInput?false:ShowTimeInput %>" />
<input type="hidden" name="orderField" value="<%=orderField %>" />
<input type="hidden" name="orderDirection" value="<%=orderDirection %>" />
<input type="hidden" name="pageNum" value="1" />
<input type="hidden" name="numPerPage" value="<%=numPerPage %>" />
</form>
<form id="form1" runat="server" method="post" action="UserModel/U4008RecordList.aspx" onsubmit="return navTabSearch(this);">
<div class="pageHeader">
    <div class="searchBar">
        <table class="searchContent">
            <tr>                 
                <td>
                    
                    机号：
                   <input name="SerialNumber" type="text" value="<%=SerialNumber %>" />
                </td>  
                <td>技师:
                <input name="RealName" type="text" value="<%=RealName %>" />
                </td>   
                <td>完成情况：
                  <select name="IsComplete" >
                    <option value="-1" <%= IsComplete==-1?"selected":"" %>>显示全部</option>
                    <option value="0" <%= IsComplete==0?"selected":"" %>>未完成</option>
                    <option value="1" <%= IsComplete==1?"selected":"" %>>已完成</option>
                </select>
                </td>           
               
            </tr>
            <tr> 
                <td  colspan="2" >
                    <input type="hidden" name="ShowTimeInput" value="<%=ShowTimeInput?false:ShowTimeInput %>" />
                    来电日期：
                   从<input name="CallDateFrom" type="text" class="date" value="<%=CallDateFrom %>" />
                   到<input name="CallDateTo" type="text" class="date" value="<%=CallDateTo %>" />
                </td>
                <td>
                   
                     <div class="subBar">
                        <ul>
                            <li>
                                <div class="buttonActive"><div class="buttonContent"><button type="submit">检索</button></div></div>
                            </li>
                        </ul>
                    </div>
                
                </td>
            </tr>
        </table>       
    </div>
</div>
<div class="pageContent">
    <div class="panelBar">
        <ul class="toolBar">
             <% if (HasPower(IHISCETeim.Web.Permission.查看))
             {%>
            <li><a class="add" href="UserModel/U4008RecordView.aspx?U4RID={sid_user}" target="navTab" title="查看来电记录" rel="U4008RecordView"><span>查看</span></a></li>
           <%} %>
          <% if (HasPower(IHISCETeim.Web.Permission.新增))
             {%>
            <li><a class="add" href="UserModel/U4008RecordAdd.aspx" target="navTab" title="添加来电记录" rel="U4008RecordAdd"><span>添加</span></a></li>
           <%} %>
             <% if (HasPower(IHISCETeim.Web.Permission.修改))
             {%>
            <li><a class="add" href="UserModel/U4008RecordEdit.aspx?U4RID={sid_user}" target="navTab" title="修改来电记录" rel="U4008RecordEdit"><span>修改</span></a></li>
           <%} %>
           <% if (HasPower(IHISCETeim.Web.Permission.删除))
               {%>
            <li><a class="delete" href="sysAjaxDone.ashx?ajaxmethod=DeleteU4008Record&U4RID={sid_user}" target="ajaxTodo" title="确定要删除吗?"><span>删除</span></a></li>
           <%} %>
           <li><a class="icon" href="UserModel/ExportExecl/ExportU4008RecordList.aspx?orderField=<%=orderField %>&orderDirection=<%=orderDirection %>&CallDateFrom=<%=CallDateFrom %>&CallDateTo=<%=CallDateTo %>&SerialNumber=<%=SerialNumber %>&RealName=<%= Server.UrlEncode( RealName) %>&IsComplete=<%= IsComplete%>" target="_blank" title="确定要导出吗?"><span>导出</span></a></li>
        </ul>
    </div>
    <asp:repeater id="rpMenu" runat="server">
        <HeaderTemplate>
        <table class="table" width="1100" layouth="136">
        <thead>
            <tr>
                <th  orderField="SerialNumber" class="asc" width="80px">
                    机号
                </th>
                <th orderField="CallDate" class="asc" width="80px">
                    来电日期
                </th>                
                <th width="80px">
                    客户姓名
                </th>
                <th  align="center" width="80px">
                   联系电话
                </th>                
                <th width="80px">
                   工作小时
                </th>  
                 <th width="80px">
                    经销商
                </th>
                 <th width="80px">
                    服务电话
                </th>
                <th>问题</th>
                <th width="80px">
                   转技师
                </th>             
                
                <th width="80px">
                    答复时间
                </th>               
                <th width="80px">
                    是否完成
                </th> 
                <th width="80px">
                    完成时间
                </th>                              
            </tr>
        </thead>
        <tbody>
        </HeaderTemplate>
        <ItemTemplate>
            <tr title="双击可查看明细" target="sid_user" rel="<%# Eval("U4RID") %>" ondblclick="navTab.openTab('U4008RecordEdit', 'UserModel/U4008RecordReplayEdit.aspx?U4RID=<%# Eval("U4RID") %>', { title:'查看回复记录'})"><td>
                <%# Eval("SerialNumber")%>
                </td>
                <td><%# Convert.ToDateTime(Eval("CallDate")).ToString("yyyy-MM-dd")%></td>
				<td><%# Eval("CustomerName")%></td>                
				<td><%# Eval("CustomerTel")%></td>
                <td><%# Eval("WorkHours")%></td>
                <td><%# Eval("AgentName")%></td>
                <td><%# Eval("AgentTel") %></td>
                  <td title="<%# Eval("Problemdescription")%>"><%# Eval("Problemdescription")%></td>
                <td><%# Eval("RealName")%></td>				
               <%-- <td><%# Eval("ReplayDate") is DBNull?"": Convert.ToDateTime(Eval("ReplayDate")).ToString("yyyy-MM-dd")%></td>--%>
                <td>
                    <a href="UserModel/U4008RecordReplayEdit.aspx?U4RID=<%# Eval("U4RID") %>" target="navTab" title="查看回复记录" rel="U4008RecordEdit">
                        <%# Eval("ReplayDate") is DBNull?"": Convert.ToDateTime(Eval("ReplayDate")).ToString("yyyy-MM-dd")%>  
                    </a>  
                </td>
                <td><%# Convert.ToBoolean(Eval("IsComplete")) ? "完成" : "<b style='color:red'>未完成</b>"%></td>
               <td><%# Eval("CompleteDate") is DBNull ? "" : Convert.ToDateTime(Eval("CompleteDate")).ToString("yyyy-MM-dd")%></td>
			</tr>
        </ItemTemplate>
        <FooterTemplate>
            </tbody>
         </table>
        </FooterTemplate>
    </asp:repeater>
    <div class="panelBar">
        <div class="pages">
            <span>显示</span>
            <select class="combox" name="numPerPage" onchange="navTabPageBreak({numPerPage:this.value})">
               <%=SetnumPerPage() %>
            </select>
            <span>条，共<%=TotalCount%>条</span>
        </div>
        <div class="pagination" targettype="navTab" totalcount="<%=TotalCount%>" numperpage="<%=numPerPage %>"
            pagenumshown="10" currentpage="<%=pageNum %>">
        </div>
    </div>
</div>
</form>
